#pragma once

#include "GraphData.h"
#include "Skeleton.h"
#include <vector>
#include <map>
#include <utility>
#include <tuple>

// struct Binding {
//     std::pair<int, int> edge;
//     std::pair<double, double> midpoint;
//     std::pair<double, double> nearest;
//     int clusterId;
// };


struct BindingInfo {
    Edge edge;
    std::pair<double, double> midpoint;
    std::pair<double, double> nearest;
    int clusterId;
};

std::vector<BindingInfo> computeBindings(
    const std::vector<Node>& nodes,
    const std::unordered_map<int, std::vector<EdgeSegment>>& skeletons,
    const std::vector<std::vector<Edge>>& clusteredEdges,
    int k,
    double sigma
);